<template>
  <div>
    <h2>Cart</h2>
    <h3>root</h3>
    <button @click="say('hahaha')">say</button>
    <h3>cart</h3>
    <button @click="cartSay('hahaha')">say</button>

    <h3>shop</h3>
    <button @click="shopSay('hahaha')">say</button>

    <h3>localShop</h3>
    <button @click="localShopSay('hahaha')">say</button>

  </div>
</template>
<script>

import { mapActions } from 'vuex'
const a1 = mapActions(['say']);
const a2 = mapActions('cart', {
  cartSay: 'say'
});
const a3 = mapActions('shop', {
  shopSay: 'say'
});
const a4 = mapActions('shop/localShop', {
  localShopSay: 'say'
});
export default {
  methods: {
    ...a1,
    ...a2,
    ...a3,
    ...a4,

  }
}
</script>